package aiproject3;

import aiproject3.util.FileGenerator;
import aiproject3.util.FileParser;
import sequences.*;
import sequences.CharSequence;

public class FileGenerationProgram {

    
    public static void main(String[] args) {
        
        String[] trainFilenames = {"essay1a", "essay2a", "essay3a", "essay4a", "essay5a"};
        String[] testFilenames = {"essay1b", "essay2b", "essay3b", "essay4b", "essay5b"};
        
        String inputPath = "textFiles/";
        String testPath = "groupTesting/";
        String trainPath = "groupTraining/";
        String test = "GroupTest_";
        String train = "GroupTrain_";
        String suffix = ".txt";
        
        FileParser fp = new FileParser("");
        
        for(int i = 0; i < trainFilenames.length; i++) {
            
            System.out.println("Parsing file " + (i+1));
            fp.setInputName(inputPath + trainFilenames[i] + suffix);
            
            fp.parseFile(trainPath + train + i + suffix);
            
            fp.setInputName(inputPath + testFilenames[i] + suffix);
            
            fp.parseFile(testPath + test + i + suffix);
        }
        
    }

}
